fun add1(number1: Int, number2: Int): Int {
        return number1 + number2
}
fun main() {
    println(add1(1,2));
    println(lenMethod(1,2,3,4,5))
    var addMethod : (Int, Int) -> Int = {number1, number2 -> number1 + number2}
    println(addMethod(2,3))

}
fun sum(number1:Int, number2: Int) = number1 + number2//返回类型 == 类型推导
fun lenMethod(vararg numbers: Int) {
    for (i in numbers) {
        println(i)
    }
}
//
fun math(vararg value: Int): Int{
    var sum = 0
    for (i in value) {
        sum += i
    }
    return sum
}
